<?xml version="1.0" encoding="UTF-8"?>
<html filename="docs/SAXHelpers/TDefaultHandler.html">
<body>
<a id="#top"/>
<h1>
	                Class Summary : TDefaultHandler </h1> Default base class for SAX2 event handlers.

 <blockquote>
 <em>This module, both source code and documentation, is in the
 Public Domain, and comes with <strong>NO WARRANTY</strong>.</em>
 </blockquote>

 <p>This class is available as a convenience base class for SAX2
 applications: it provides default implementations for all of the
 callbacks in the four core SAX2 handler classes:</p>

 <ul>
 <li>
        <a href="../SAX/IEntityResolver.html">IEntityResolver</a>
      </li>
 <li>
        <a href="../SAX/IDTDHandler.html">IDTDHandler</a>
      </li>
 <li>
        <a href="../SAX/IContentHandler.html">IContentHandler</a>
      </li>
 <li>
        <a href="../SAX/IErrorHandler.html">IErrorHandler</a>
      </li>
 </ul>

 <p>Application writers can extend this class when they need to
 implement only part of an interface; parser writers can
 instantiate this class to provide default handlers when the
 application has not supplied its own.</p>

 <p>This class replaces the deprecated SAX1
 HandlerBase class.</p>

<br/><b>Since : </b> SAX 2.0
<br/><b>See : </b> <a href="../SAX/IEntityResolver.html">IEntityResolver</a>
<br/><b>See : </b> <a href="../SAX/IDTDHandler.html">IDTDHandler</a>
<br/><b>See : </b> <a href="../SAX/IContentHandler.html">IContentHandler</a>
<br/><b>See : </b> <a href="../SAX/IErrorHandler.html">IErrorHandler</a>
<h2>
	              Methods
	            </h2>
<div style="padding-left:10px">
<a href="#resolveEntity">
	                  function
	                 resolveEntity(SAXString, SAXString) : IInputSource</a>
<br/>
<a href="#notationDecl">
	                  procedure
	                 notationDecl(SAXString, SAXString, SAXString)</a>
<br/>
<a href="#unparsedEntityDecl">
	                  procedure
	                 unparsedEntityDecl(SAXString, SAXString, SAXString, SAXString)</a>
<br/>
<a href="#setDocumentLocator">
	                  procedure
	                 setDocumentLocator(ILocator)</a>
<br/>
<a href="#startDocument">
	                  procedure
	                 startDocument()</a>
<br/>
<a href="#endDocument">
	                  procedure
	                 endDocument()</a>
<br/>
<a href="#startPrefixMapping">
	                  procedure
	                 startPrefixMapping(SAXString, SAXString)</a>
<br/>
<a href="#endPrefixMapping">
	                  procedure
	                 endPrefixMapping(SAXString)</a>
<br/>
<a href="#startElement">
	                  procedure
	                 startElement(SAXString, SAXString, SAXString, IAttributes)</a>
<br/>
<a href="#endElement">
	                  procedure
	                 endElement(SAXString, SAXString, SAXString)</a>
<br/>
<a href="#characters">
	                  procedure
	                 characters(SAXString)</a>
<br/>
<a href="#ignorableWhitespace">
	                  procedure
	                 ignorableWhitespace(SAXString)</a>
<br/>
<a href="#processingInstruction">
	                  procedure
	                 processingInstruction(SAXString, SAXString)</a>
<br/>
<a href="#skippedEntity">
	                  procedure
	                 skippedEntity(SAXString)</a>
<br/>
<a href="#warning">
	                  procedure
	                 warning(ISAXParseError)</a>
<br/>
<a href="#error">
	                  procedure
	                 error(ISAXParseError)</a>
<br/>
<a href="#fatalError">
	                  procedure
	                 fatalError(ISAXParseError)</a>
<br/>
</div>
<br/>
<hr width="100%"/>
<a name="#resolveEntity">
<p>
<b>function</b> resolveEntity(<b>const</b> publicId : SAXString; <b>const</b> systemId : SAXString) : IInputSource; </p>
</a> Resolve an external entity.

 <p>Always return nil, so that the parser will use the system
 identifier provided in the XML document.  This method implements
 the SAX default behaviour: application writers can override it
 in a subclass to do special translations such as catalog lookups
 or URI redirection.</p>

<br/><b>Parameter : </b> publicId The public identifer, or an empty string if none is
                 available.
<br/><b>Parameter : </b> systemId The system identifier provided in the XML
                 document.
<br/><b>Result : </b> The new input source, or nil to require the
         default behaviour.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IEntityResolver.html#resolveEntity">IEntityResolver.resolveEntity</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#notationDecl">
<p>
<b>procedure</b> notationDecl(<b>const</b> name : SAXString; <b>const</b> publicId : SAXString; <b>const</b> systemId : SAXString); </p>
</a> Receive notification of a notation declaration.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass if they wish to keep track of the notations
 declared in a document.</p>

<br/><b>Parameter : </b> name The notation name.
<br/><b>Parameter : </b> publicId The notation public identifier, or an empty string
                 if not available.
<br/><b>Parameter : </b> systemId The notation system identifier.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IDTDHandler.html#notationDecl">IDTDHandler.notationDecl</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#unparsedEntityDecl">
<p>
<b>procedure</b> unparsedEntityDecl(<b>const</b> name : SAXString; <b>const</b> publicId : SAXString; <b>const</b> systemId : SAXString; <b>const</b> notationName : SAXString); </p>
</a> Receive notification of an unparsed entity declaration.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass to keep track of the unparsed entities
 declared in a document.</p>

<br/><b>Parameter : </b> name The entity name.
<br/><b>Parameter : </b> publicId The entity public identifier, or an empty string
                 if not available.
<br/><b>Parameter : </b> systemId The entity system identifier.
<br/><b>Parameter : </b> notationName The name of the associated notation.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IDTDHandler.html#unparsedEntityDecl">IDTDHandler.unparsedEntityDecl</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#setDocumentLocator">
<p>
<b>procedure</b> setDocumentLocator(<b>const</b> Locator : ILocator); </p>
</a> Receive a Locator object for document events.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass if they wish to store the locator for use
 with other document events.</p>

<br/><b>Parameter : </b> locator A locator for all SAX document events.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#setDocumentLocator">IContentHandler.setDocumentLocator</a>
<br/><b>See : </b> <a href="../SAX/ILocator.html">ILocator</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#startDocument">
<p>
<b>procedure</b> startDocument(); </p>
</a> Receive notification of the beginning of the document.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass to take specific actions at the beginning
 of a document (such as allocating the root node of a tree or
 creating an output file).</p>

<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#startDocument">IContentHandler.startDocument</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#endDocument">
<p>
<b>procedure</b> endDocument(); </p>
</a> Receive notification of the end of the document.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass to take specific actions at the end
 of a document (such as finalising a tree or closing an output
 file).</p>

<br/><b>Exception : </b> ESAXException Any SAX exception
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#endDocument">IContentHandler.endDocument</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#startPrefixMapping">
<p>
<b>procedure</b> startPrefixMapping(<b>const</b> prefix : SAXString; <b>const</b> uri : SAXString); </p>
</a> Receive notification of the start of a Namespace mapping.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass to take specific actions at the start of
 each Namespace prefix scope (such as storing the prefix mapping).</p>

<br/><b>Parameter : </b> prefix The Namespace prefix being declared.
<br/><b>Parameter : </b> uri The Namespace URI mapped to the prefix.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#startPrefixMapping">IContentHandler.startPrefixMapping</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#endPrefixMapping">
<p>
<b>procedure</b> endPrefixMapping(<b>const</b> prefix : SAXString); </p>
</a> Receive notification of the end of a Namespace mapping.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass to take specific actions at the end of
 each prefix mapping.</p>

<br/><b>Parameter : </b> prefix The Namespace prefix being declared.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#endPrefixMapping">IContentHandler.endPrefixMapping</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#startElement">
<p>
<b>procedure</b> startElement(<b>const</b> uri : SAXString; <b>const</b> localName : SAXString; <b>const</b> qName : SAXString; <b>const</b> atts : IAttributes); </p>
</a> Receive notification of the start of an element.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass to take specific actions at the start of
 each element (such as allocating a new tree node or writing
 output to a file).</p>

<br/><b>Parameter : </b> uri The Namespace URI, or the empty string if the
        element has no Namespace URI or if Namespace
        processing is not being performed.
<br/><b>Parameter : </b> localName The local name (without prefix), or the
        empty string if Namespace processing is not being
        performed.
<br/><b>Parameter : </b> qName The qualified name (with prefix), or the
        empty string if qualified names are not available.
<br/><b>Parameter : </b> atts The attributes attached to the element.  If
        there are no attributes, it shall be an empty
        Attributes object.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#startElement">IContentHandler.startElement</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#endElement">
<p>
<b>procedure</b> endElement(<b>const</b> uri : SAXString; <b>const</b> localName : SAXString; <b>const</b> qName : SAXString); </p>
</a> Receive notification of the end of an element.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass to take specific actions at the end of
 each element (such as finalising a tree node or writing
 output to a file).</p>

<br/><b>Parameter : </b> uri The Namespace URI, or the empty string if the
        element has no Namespace URI or if Namespace
        processing is not being performed.
<br/><b>Parameter : </b> localName The local name (without prefix), or the
        empty string if Namespace processing is not being
        performed.
<br/><b>Parameter : </b> qName The qualified name (with prefix), or the
        empty string if qualified names are not available.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#endElement">IContentHandler.endElement</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#characters">
<p>
<b>procedure</b> characters(<b>const</b> ch : SAXString); </p>
</a> Receive notification of character data inside an element.

 <p>By default, do nothing.  Application writers may override this
 method to take specific actions for each chunk of character data
 (such as adding the data to a node or buffer, or printing it to
 a file).</p>

<br/><b>Parameter : </b> ch The characters from the XML Document.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#characters">IContentHandler.characters</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#ignorableWhitespace">
<p>
<b>procedure</b> ignorableWhitespace(<b>const</b> ch : SAXString); </p>
</a> Receive notification of ignorable whitespace in element content.

 <p>By default, do nothing.  Application writers may override this
 method to take specific actions for each chunk of ignorable
 whitespace (such as adding data to a node or buffer, or printing
 it to a file).</p>

<br/><b>Parameter : </b> ch The whitespace characters.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#ignorableWhitespace">IContentHandler.ignorableWhitespace</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#processingInstruction">
<p>
<b>procedure</b> processingInstruction(<b>const</b> target : SAXString; <b>const</b> data : SAXString); </p>
</a> Receive notification of a processing instruction.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass to take specific actions for each
 processing instruction, such as setting status variables or
 invoking other methods.</p>

<br/><b>Parameter : </b> target The processing instruction target.
<br/><b>Parameter : </b> data The processing instruction data, or an empty string if
             none is supplied.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#processingInstruction">IContentHandler.processingInstruction</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#skippedEntity">
<p>
<b>procedure</b> skippedEntity(<b>const</b> name : SAXString); </p>
</a> Receive notification of a skipped entity.

 <p>By default, do nothing.  Application writers may override this
 method in a subclass to take specific actions for each
 processing instruction, such as setting status variables or
 invoking other methods.</p>

<br/><b>Parameter : </b> name The name of the skipped entity.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IContentHandler.html#processingInstruction">IContentHandler.processingInstruction</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#warning">
<p>
<b>procedure</b> warning(<b>const</b> e : ISAXParseError); </p>
</a> Receive notification of a parser warning.

 <p>The default implementation does nothing.  Application writers
 may override this method in a subclass to take specific actions
 for each warning, such as inserting the message in a log file or
 printing it to the console.</p>

<br/><b>Parameter : </b> e The warning information encoded as an exception.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IErrorHandler.html#warning">IErrorHandler.warning</a>
<br/><b>See : </b> <a href="../SAX/ESAXParseException.html">ESAXParseException</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#error">
<p>
<b>procedure</b> error(<b>const</b> e : ISAXParseError); </p>
</a> Receive notification of a recoverable parser error.

 <p>The default implementation does nothing.  Application writers
 may override this method in a subclass to take specific actions
 for each error, such as inserting the message in a log file or
 printing it to the console.</p>

<br/><b>Parameter : </b> e The warning information encoded as an exception.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IErrorHandler.html#warning">IErrorHandler.warning</a>
<br/><b>See : </b> <a href="../SAX/ESAXParseException.html">ESAXParseException</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
<hr width="100%"/>
<a name="#fatalError">
<p>
<b>procedure</b> fatalError(<b>const</b> e : ISAXParseError); </p>
</a> Report a fatal XML parsing error.

 <p>The default implementation throws a SAXParseException.
 Application writers may override this method in a subclass if
 they need to take specific actions for each fatal error (such as
 collecting all of the errors into a single report): in any case,
 the application must stop all regular processing when this
 method is invoked, since the document is no longer reliable, and
 the parser may no longer report parsing events.</p>

<br/><b>Parameter : </b> e The error information encoded as an exception.
<br/><b>Exception : </b> ESAXException Any SAX exception.
<br/><b>See : </b> <a href="../SAX/IErrorHandler.html#fatalError">IErrorHandler.fatalError</a>
<br/><b>See : </b> <a href="../SAX/ESAXParseException.html">ESAXParseException</a>
<br/>
<p>
<a href="#top">Top</a>
</p>
</body>
</html>